package com.lvy.hczn.front.system.domain.business;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.lvy.hczn.front.common.core.domain.BaseModel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;
import java.time.LocalDate;
import java.util.List;

@Data
@TableName("spu")
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "原料")
public class Spu extends BaseModel<Spu> {

    @ApiModelProperty(value = "来源ID")
    private String sourceId;

    @ApiModelProperty(value = "原料编号")
    private String spuCode;


    @ApiModelProperty(value = "供应商编码")
    private String supplierCode;

    @ApiModelProperty(value = "名称")
    private String name;

    @ApiModelProperty(value = "品类")
    private String categoryId;

    @ApiModelProperty(value = "是否包装盒 0原料，1包装合 默认0")
    private String isPackingBox;

    @ApiModelProperty(value = "保质期(品类保质期预留，入库单输入保质期为主，供应商乱输保质期不管，入库单保质期>原料保质期>品类保质期)")
    private LocalDate shelfLife;

    @ApiModelProperty("货箱重量误差范围最小值")
    private BigDecimal errorMin;

    @ApiModelProperty("货箱重量误差范围最大值")
    private BigDecimal errorMax;

    @ApiModelProperty(value = "温区编码")
    private Integer temperatureZoneCode;

    @ApiModelProperty(value = "商品主图")
    private String imgUrl;

    @ApiModelProperty(value = "是否大件0:否,1:是")
    private Integer bigProduct;

    @ApiModelProperty(value = "是否标品，0：否；1：是")
    private Integer standard;

    @ApiModelProperty(value = "原料是否需要生产加工，0：否；1：是")
    private Integer materialProcess;

    @ApiModelProperty(value = "sku")
    @TableField(exist = false)
    private List<Sku> list;
}
